//api文件仍保留但不建议使用，推荐使用models中的api。API files remain preserved (deprecated), use models APIs instead.
import type { MinishopGoodsComment, MinishopGoodsCommentResponse } from './types.js';

import { requestClient } from '#/api/request';

export const getuctooMinishopGoodsCommentList = async (page: number, pageSize: number,
  searchParams?: any) => {
  return requestClient.get<MinishopGoodsCommentResponse>(`/uctoo/minishop_goods_comment/${pageSize}/${page}`,{
    params: searchParams,
  });
};

export const getuctooMinishopGoodsComment = async (id: string) => {
  return requestClient.get<MinishopGoodsComment>(`/uctoo/minishop_goods_comment/${id}`);
};

export const adductooMinishopGoodsComment = async (data: Partial<MinishopGoodsComment>) => {
  return requestClient.post<MinishopGoodsComment>('/uctoo/minishop_goods_comment/add', data);
};

export const edituctooMinishopGoodsComment = async (data: Partial<MinishopGoodsComment>) => {
  return requestClient.post<MinishopGoodsComment>('/uctoo/minishop_goods_comment/edit', data);
};

export const deleteuctooMinishopGoodsComment = async (id: string) => {
  return requestClient.post<any>('/uctoo/minishop_goods_comment/del', { id });
};
